package com.welyo.model.quizz {
	/**
	 * ...
	 * @author vu.doan
	 */
	public class BaseQuestionItemVO {
		
		private var label			:String;
		private var arrAnswer		:Array;
		private var correctAnswer	:String;
		
		public function BaseQuestionItemVO(data:XML) {
			label = data.label.toString();
			correctAnswer = data.@answer.toString();
			arrAnswer = [];
			
			var obj:Object;
			for (var i:int = 0; i < data.answer.length(); i++) {
				obj = {id:data.answer[i].@id, label:data.answer[i].toString()};
				arrAnswer.push(obj);
			}
		}
		
		public function get Label():String {
			return label;
		}
		
		public function get Answers():Array {
			return arrAnswer;
		}
		
		public function get CorrectAnswer():String {
			return correctAnswer;
		}
	}
}